<?php
class Createfile {

    protected $db = null;

    public function __construct($db) {
	$this->db = $db;
    }

    public function __destruct() {
	unset($this->db);
    }

	
	
	

	/**
	* 	create group cate file 生成分类文件,PHP及json
	*/
	/*public function create_cate(){
		$sql  = "select cate_id as id,cate_title as title,cate_pid as pid from data_cate order by cate_order";	
		$data = $this->db->getAll($sql);
		if($data){
			
			$newdata = $this->loop_data(0,$data,'pid','id');
			$new_array = var_export($newdata,true);
			$input_data= "\$cf_var_cate=".$new_array;
			write_file(INFO_PATH."cf_var_cate".$type.".php",$input_data);
			
			$newdata2 = $this->loop_data(0,$data,'pid','id',0);
			$json = json_encode($newdata2);
			write_file(INFO_PATH."cf_var_cate".$type.".js",$json,"js");
			
		}
		
	}*/
}

?>